<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" 
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml"
	xmlns:ui="http://java.sun.com/jsf/facelets"
	xmlns:h="http://java.sun.com/jsf/html"
	xmlns:f="http://java.sun.com/jsf/core"
	xmlns:p="http://primefaces.org/ui">
	
	<h:head>
		<title>Teste - JSF</title>
	</h:head>
	
	<h:body>
		<p:fieldset id="cadastro" legend="Cadastro" toggleable="true">
			<h:outputText value="Nome:"/>
			<p:inputText id="nome" value="#{beanCliente.nome}"/>			
			<h:outputText value="Observações:" />
			<p:inputTextarea value="#{beanCliente.observacao}"/>
			<h:outputText value="Data cadastro:"/>
			<p:calendar value="#{beanCliente.dataCadastro}"/>
			<h:outputText value="Telefone:"/>
			<p:inputMask mask="(999)9999-9999" value="#{beanCliente.telefone}"/>
			<h:outputText value="CPF:"/>
			<p:inputMask mask="(999.999.999-99)" value="#{beanCliente.cpf}"/>
			<h:outputText value="Descrição:"/>
			<p:keyboard layout="qwertyBasic" value="#{beanCliente.descricao}"/>
			<p:separator style="width:90%; height:5px"/>
			<p:focus for="nome"/>
		</p:fieldset>
			<p:fieldset id="mensagens" legend="Mensagem" toggleable="true">
	 		<p:editor id="editor" control="color highlight removeformat | outdent indent | rule image link unlink | 
	 		cut copy paste pastetext | print source">
			</p:editor>
		<!-- <h:commandButton value="Salvar" action="#{beanCliente.salvar}" /> -->		
		<p:commandButton value="Salvar" actionListener="#{beanCliente.testar}" update="mensagens,cadastro" />
		</p:fieldset>
	</h:body>

</html>